xml.shim do
  xml.name(@shim.name)
  xml.processor do
    case @shim.shim_type
      when "BeanShell"
        xml.beanshell(@shim.shim_blob.data)
      when "Other" || "Workflow"
      else
    end  
  end
  xml.annotations do  
    for a in @shim.annotations
      xml.annotation({"type"=>a.attribute_name},a.value)
    end
  end
  xml.inputs do
    for i in @shim_inputs
      xml.input do
        xml.name(i.name)
        xml.annotations do  
          for a in i.annotations
            xml.annotation({"type"=>a.attribute_name},a.value)
          end
        end
        xml.linked_services do
          for s in i.services
            xml.service(s.name)
          end
        end
      end
    end
  end
  xml.outputs do
    for o in @shim_outputs
      xml.output do
        xml.name(o.name)
        xml.annotations do  
          for a in o.annotations
            xml.annotation({"type"=>a.attribute_name},a.value)
          end
        end
        xml.linked_services do
          for s in o.services
            xml.service(s.name)
          end
        end
      end      
    end    
  end
end
